The invention relates to integrated circuit microcontrollers, and, more particularly, to an integrated circuit microcontroller having an integral peripheral analog comparator that is programmable for either low-power or high-speed operation.
Integrated circuit microcontrollers are becoming far more sophisticated while continuing to drop in price. More and more consumer and commercial products, such as for example but not limited to, appliances, telecommunications devices, automobiles, security systems, full-house instant hot water heaters, thermostats, and the like are being controlled by these integrated circuit microcontrollers. Analog inputs for receiving sensor information and analog outputs for controlling functions are necessary for the application of these microcontrollers. Heretofore separate and discrete analog interfaces were used to connect the digital microcontroller to the outside world.
Analog input devices such as an analog-to-digital converter (ADC), in conjunction with a separate operational amplifier, were used to convert a time-varying analog signal into digital representations thereof for application to digital inputs and use thereof by the microcontroller. Voltage and current levels were also detected by discrete integrated circuit voltage comparators that changed a digital output state when a certain analog value was present on the input of the comparator.
Different applications required different speeds for the ADC-Op Amp and the comparators. This was not a problem since the ADC-OP Amp and the comparators were separate integrated circuit devices that could be selected for the specific applications. Technology has now advanced to the point where the analog input and output devices can be fabricated on the same integrated circuit die that the digital microcontroller and its support logic and memories are also fabricated.
A problem exists, however, in that these analog input microcontrollers must interface with very different analog input parameters such as speed, gain, offset, common mode rejection, linearity and the like. In addition, different applications of the analog input microcontroller may have restrictions on the amount of power available to run the microcontroller and its integral analog peripherals. Since there are so many different combinations of analog input and systems parameters, a great number of different types of integrated circuit analog input microcontrollers are required. This preclude cost reductions because there is no economics of scale through the possibility of increased production quantities.
What is needed is an integrated circuit microcontroller having analog input peripherals that can be used for measurement and control applications requiring different analog input parameters, and can be further mass-produced to reduce overall product costs.
The invention overcomes the above-identified problems, as well as other shortcomings and deficiencies of existing technologies, by providing, in a single integrated circuit package, a microcontroller system having at least one analog input peripheral device, such as an operational amplifier and/or a voltage comparator, that can be programmed to have specific characteristics and parameters which are adapted for various requirements in the measurement of analog signals of a specific application. In another embodiment of the invention, a plurality of analog input peripheral devices, each having a different characteristic than the others, is programmably selectable for a specific operation with the microcontroller. In still another embodiment, at least one programmable analog comparator is fabricated in an integrated circuit package, and may be configured for an appropriate application of the electronic system of which it is part.
In an embodiment of the programmable comparator of the present invention, the comparator has at least the following two modes: a high-speed mode where power consumption is not an issue, and a low-power mode where speed is not required but conservation of power is desirable, such as when using a battery or other low-power type operation. Selection of either the high-speed or low-power mode is accomplished without using a clocking scheme or logic therefor. Switching between the low-power and high-speed modes may be done dynamically, depending on changing application requirements.
The comparator may be enabled or disabled by setting or clearing, respectively, an input control bit to further save power when it is not in use. The programmable comparator has a first stage that is adapted to have its parameters configured by connection to one of two current sources, or one current source having switchable current modes. The first current source/mode configures the first stage of the comparator for high-speed operation. Subsequent stages of the comparator are affected by the current usage of the first stage; thus, the first current source/mode will determine the speed and power usage of the entire comparator circuit. In similar fashion, the second current source/mode configures the first stage of the comparator for low-power operation. As a result, subsequent stages of the comparator are also configured for low-power operation due to the signal biasing between stages.
A feature of the invention is configuring the operation of an analog comparator for either high-speed or low-power operation.
Another feature is at least one programmable multiple use analog comparator integral with a microcontroller on an integrated circuit die.
Still another feature is at least one programmable multiple-use analog comparator that is integral with a microcontroller in an integrated circuit package.
Another feature is programmably switching the operating mode of an analog comparator that is integral with a microcontroller on an integrated circuit die.
Another feature is at least one programmable multiple-use analog comparator in an integrated circuit package.
An advantage of the present invention is using a microcontroller and a programmable analog comparator fabricated on one integrated circuit die or in a multi-chip package (MCP) for a broad range of applications.
Another advantage is being able to dynamically change the comparator operating parameters as required by the application.
Still another advantage is reducing the number of different comparators and microcontrollers.
Another advantage is eliminating the requirement for a stand-alone comparator with a microcontroller integrated circuit package on a system printed circuit board.
Other and further features and advantages will be apparent from the following description of presently preferred embodiments of the invention, given for the purpose of disclosure and taken in conjunction with the accompanying drawings.